<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript">
        var obj = {
            name: "xzc",
            age: 18,
            fun: function () {
                alert(this.name + this.age)
            }
        }
        obj.fun();
    </script>
</head>
<body>

</body>
</html>